package org.familysearch.fsapi.gwt.common.client.callbacks;

import com.google.gwt.core.client.GWT;
import com.google.gwt.dom.client.Document;
import com.google.gwt.http.client.Request;
import com.google.gwt.http.client.RequestCallback;
import com.google.gwt.http.client.Response;
import com.google.gwt.xml.client.XMLParser;

public class PersonReadRequestCallback implements RequestCallback {

	
	
	public PersonReadRequestCallback()
	{
		
	}

	public void onError(Request request, Throwable exception) {
		GWT.log(exception.getMessage(), null);
	}

	public void onResponseReceived(Request request, Response response) {
		
		Document document = (Document) XMLParser.parse(response.getText());
		GWT.log(document.toString(), null);
		
	}
	
	
}
